package com.kexun.common.enums;

public enum PayChanel {
    支付宝(0, "支付宝"),
    余额(1, "余额"),
    ;

    private int status;

    private String name;

    PayChanel(int status, String name) {
        this.status = status;
        this.name = name;
    }

    public static String getName(int status) {
        for (PayChanel c : PayChanel.values()) {
            if (c.getStatus() == status) {
                return c.name;
            }
        }
        return null;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
